# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=yuck
pkgver=1072.b28436e
pkgrel=1
pkgdesc='A bog-standard command line option parser for C that works with only household ingredients.'
url='https://github.com/hroptatyr/yuck'
arch=('x86_64' 'aarch64')
license=('BSD')
depends=('keystone' 'capstone')
makedepends=('git')
source=("git+https://github.com/hroptatyr/$pkgname.git")
sha512sums=('SKIP')

pkgver() {
  cd $pkgname

  echo $(git rev-list --count HEAD).$(git rev-parse --short HEAD)
}

build() {
  cd $pkgname

  autoreconf -fi

  ./configure --prefix=/usr

  make
}

package() {
  cd $pkgname

  make DESTDIR="$pkgdir" install

  install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README.md
}

